package cn.iocoder.yudao.module.mybusiness.domain;

import lombok.Data;

@Data
public class Job implements Comparable<Job> {
    int id;
    int processingTime;
    long modId;

    public Job(int id, int processingTime, long modId) {
        this.id = id;
        this.processingTime = processingTime;
        this.modId = modId;
    }

    // 实现Comparable接口以便能按处理时间排序
    @Override
    public int compareTo(Job other) {
        return other.processingTime-this.processingTime ;
    }
}
